﻿package com.assist.view.info
{

    public class FurnaceInfo extends Object
    {
        private var _curRoleList:Array;
        private var _stoveObj:Object;
        private var _makeResult:Array;
        public var opRoleId:int;
        public var exp:int;
        public var result:int;
        public var iInfoArr:Array;

        public function FurnaceInfo()
        {
            this.iInfoArr = new Array();
            return;
        }// end function

        public function set curRoleList(param1:Array) : void
        {
            this._curRoleList = param1;
            return;
        }// end function

        public function get curRoleList() : Array
        {
            if (this._curRoleList)
            {
                return this._curRoleList;
            }
            return new Array();
        }// end function

        public function set stoveObj(param1:Object) : void
        {
            this._stoveObj = param1;
            return;
        }// end function

        public function get stoveObj() : Object
        {
            if (this.stoveObj)
            {
                return this.stoveObj;
            }
            return {itemId:0, itemAmount:0};
        }// end function

        public function set makeResult(param1:Array) : void
        {
            this._makeResult = param1;
            return;
        }// end function

        public function get makeResult() : Array
        {
            if (this._makeResult)
            {
                return this._makeResult;
            }
            return new Array();
        }// end function

        public function levelRole(param1:int) : Object
        {
            var _loc_3:Object = null;
            var _loc_2:int = 0;
            while (_loc_2 < this.curRoleList.length)
            {
                
                _loc_3 = this.curRoleList[_loc_2];
                if (_loc_3.roleId == param1)
                {
                    this._curRoleList[_loc_2] = _loc_3.childObj;
                    return this._curRoleList[_loc_2];
                }
                _loc_2++;
            }
            return new Object();
        }// end function

        public function getInfoByRoleId(param1:int) : Object
        {
            var _loc_2:int = 0;
            while (_loc_2 < this.curRoleList.length)
            {
                
                if (this.curRoleList[_loc_2].roleId == param1)
                {
                    return this.curRoleList[_loc_2];
                }
                _loc_2++;
            }
            return new Object();
        }// end function

    }
}
